package cn.edu.niit.alienlab.jshttplessonserver.dao;

import cn.edu.niit.alienlab.jshttplessonserver.domain.WriterInfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface WriterInfoDao {

    /*按影片id查询编剧信息*/
    @Select("SELECT wi.*,mi.movie_id  FROM writer_info wi,movie_writers mw,movie_info mi  " +
            "WHERE mw.writer_id=wi.id AND mw.movie_id=mi.movie_id AND mi.movie_id=#{movie_id}")
    public WriterInfo selectWriterInfoByMovieId(Integer movie_id);

}
